from django.urls import path
from . import views
import os
from django.conf.urls.static import static
from django.conf import settings


urlpatterns = [
    path('', views.index_hangdler, name='index'),
    path('login/', views.login_handler, name='login'),
    path('logout', views.logout_handler, name='logout')
]


if settings.DEBUG:
    media_root = os.path.join(settings.BASE_DIR,'user')
    urlpatterns += static('/user/', document_root=media_root)
